<template>
	<view>
		<view class="workCard">
			<view>工单编号: ZX201910201</view>
			<view>变电站名称: #123</view>
			<view>日期: {{formatTime}}</view>
			<view>发现人: 张三</view>
			<view class="reason">异常原因: 变电站异常原因是变电站异常原因是变电站异常原因是</view>
		</view>
	</view>
</template>

<script>
	export default {
		props:{
			
		},
		data() {
			return {
				timeStamp:'1577030399999'
			}
		},
		computed:{
			formatTime(){ // 格式化日期
				let myDate = new Date(Number(this.timeStamp));
				let year = myDate.getFullYear()
				let month = myDate.getMonth() - 1
				let day = myDate.getDate()
				return `${year}.${month}.${day}`
			}
		},
		methods: {
			
		},
		
	}
</script>

<style scoped lang="less">
	.workCard{
		background: #FFFFFF;
		padding: 30rpx;
		.reason{
			overflow: hidden;
			white-space: nowrap;
			text-overflow: ellipsis;
		}
	}
</style>
